$OpenBSD: patch-src_libavoid_connector_cpp,v 1.1 2017/05/22 15:02:40 espie Exp $

Index: src/libavoid/connector.cpp
--- src/libavoid/connector.cpp.orig
+++ src/libavoid/connector.cpp
@@ -694,6 +694,10 @@ bool validateBendPoint(VertInf *aInf, VertInf *bInf, V
     return bendOkay;
 }
 
+template<typename T>inline T absdiff(T a, T b)
+{
+    return a < b ? b - a : a - b;
+}
 
 bool ConnRef::generatePath(void)
 {
@@ -885,7 +889,7 @@ bool ConnRef::generatePath(void)
             {
                 // Check for consecutive points on opposite 
                 // corners of two touching shapes.
-                COLA_ASSERT(abs(i->pathNext->id.objID - i->id.objID) != 2);
+                COLA_ASSERT(absdiff(i->pathNext->id.objID, i->id.objID) != 2);
             }
         }
     }
